#ifndef _ARBITER_H_
# define _ARBITER_H_

#include <iostream>
#include <list>
#include "Board.h"

class Arbiter
{
public://Ctor & Dtor
	Arbiter();
	~Arbiter();

private:
	Arbiter(Arbiter const&);
	Arbiter& operator=(Arbiter const&);

private: // Methods chief captains
	bool		IsDestinationEmpty(const int & dest_x, const int & dest_y, Board& _board) const;

public: // The General
	bool		CanIMove(const int & dest_x, const int & dest_y, BoardCase& color, Board& _board, bool _verbose = false);
	bool		IsFivePieceAligned(BoardCase& _case, Board& _board, bool _verbose = false);
	bool		CanICapture(Board& _board, BoardCase& _case, int direction, std::list<BoardCase*>& _cases);
	bool		HasCurrentPlayerWon() const;
	void		SetCurrentPlayerWin(bool _value);
	bool		RuleThree();
	void		SetRuleThree(bool _value);

private: // Variables
	bool m_ruleThree;
	bool m_currentPlayerWins;
};

#endif // _ARBITER_H_
